package org.coderk.mybatis.publisher;

import org.coderk.mybatis.event.HelloManEvent;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationEventPublisher;
import org.springframework.context.ApplicationEventPublisherAware;
import org.springframework.stereotype.Component;

/**
 * @author: TanJingyu
 * @create: 2021-04-05 15:41
 **/
@Component
public class HelloManEventPublisher {
    @Autowired
    private ApplicationEventPublisher publisher;

    public void publish() {
        publisher.publishEvent(new HelloManEvent("hello.man........."));
    }
}
